//
//  chargeDetailCell.m
//  LoveFreshBeen
//
//  Created by 胡不归是大虾 on 2016/10/20.
//  Copyright © 2016年 魏根. All rights reserved.
//

#import "chargeDetailCell.h"
@interface chargeDetailCell( )
@property (weak, nonatomic) IBOutlet UILabel *totalPriceLable;
@property (weak, nonatomic) IBOutlet UILabel *deliverFeeLable;
@property (weak, nonatomic) IBOutlet UILabel *serviceChargeLable;
@property (weak, nonatomic) IBOutlet UILabel *discountLable;



@end
@implementation chargeDetailCell

- (void)awakeFromNib {
    [super awakeFromNib];

}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}
-(void)setPrice:(CGFloat)price{
    _price = price;
    self.totalPriceLable.text = [NSString stringWithFormat:@"$%.1f",price];
    //判断总价是否大于 39
    if(price >= 39){
        self.discountLable.text = @"$5";
    }else{
        self.discountLable.text = @"$0";
    }
    //判断总价是否大于100
    if (price >= 100) {
        self.deliverFeeLable.text = @"$0";
    }else{
        self.deliverFeeLable.text = @"$8";
    }
    self.serviceChargeLable.text = @"$0";

}









@end
